.frame {
  position: absolute;
  width: 400px;
  height: 400px;
  inset: 0;
  margin: auto;
  background-color: #4b4841;
  box-shadow: 1px 2px 10px rgba(0, 0, 0, 0.3);
  border-radius: 2px;
}

.card {
  position: absolute;
  width: 320px;
  height: 180px;
  perspective: 800px;
  inset: 0;
  margin: auto;
}
.card:hover .flip {
  transform: rotateX(180deg) translate3d(0, 0, 0);
  box-shadow: 8px -10px 15px rgba(0, 0, 0, 0.5);
}
.card .flip {
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
  transition: all 1s ease-in-out;
  perspective: 1000px;
  box-shadow: 8px 10px 15px rgba(0, 0, 0, 0.5);
}
.card .front,
.card .back {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: #ffce4e;
  backface-visibility: hidden;
  border-radius: 3px;
  overflow: hidden;
  text-align: center;
}
.card .front {
  z-index: 2;
  transform: rotateX(0);
}
.card .front img {
  position: relative;
  top: 52px;
  animation: bike 0.6s ease-in-out infinite;
  transform-origin: 50% 100%;
}
.card .front .street {
  position: absolute;
  top: 127px;
  left: 80px;
  width: 160px;
  height: 3px;
  overflow: hidden;
}
.card .front .street .stripe-1 {
  position: absolute;
  right: -25px;
  top: 0;
  height: 3px;
  width: 4px;
  background: #4b4841;
  border-radius: 3px;
  animation: street 1s linear 0.7s infinite;
}
.card .front .street .stripe-2 {
  position: absolute;
  right: -25px;
  top: 0;
  height: 3px;
  width: 6px;
  background: #4b4841;
  border-radius: 3px;
  animation: street 0.9s linear 0.5s infinite;
}
.card .front .street .stripe-3 {
  position: absolute;
  right: -25px;
  top: 0;
  height: 3px;
  width: 8px;
  background: #4b4841;
  border-radius: 3px;
  animation: street 0.9s linear 0.7s infinite;
}
.card .front .street .stripe-4 {
  position: absolute;
  right: -25px;
  top: 0;
  height: 3px;
  width: 10px;
  background: #4b4841;
  border-radius: 3px;
  animation: street 0.9s linear 0.1s infinite;
}
.card .front .street .stripe-5 {
  position: absolute;
  right: -25px;
  top: 0;
  height: 3px;
  width: 12px;
  background: #4b4841;
  border-radius: 3px;
  animation: street 1s linear 0.3s infinite;
}
.card .front .street .stripe-6 {
  position: absolute;
  right: -25px;
  top: 0;
  height: 3px;
  width: 14px;
  background: #4b4841;
  border-radius: 3px;
  animation: street 1s linear 1s infinite;
}
.card .front .street .stripe-7 {
  position: absolute;
  right: -25px;
  top: 0;
  height: 3px;
  width: 16px;
  background: #4b4841;
  border-radius: 3px;
  animation: street 1s linear 0.5s infinite;
}
.card .front .street .stripe-8 {
  position: absolute;
  right: -25px;
  top: 0;
  height: 3px;
  width: 18px;
  background: #4b4841;
  border-radius: 3px;
  animation: street 0.9s linear 0.8s infinite;
}
.card .front .street .stripe-9 {
  position: absolute;
  right: -25px;
  top: 0;
  height: 3px;
  width: 20px;
  background: #4b4841;
  border-radius: 3px;
  animation: street 1s linear 0.5s infinite;
}
.card .back {
  transform: rotateX(180deg);
}
.card .back img {
  position: relative;
  z-index: 1;
  top: 57px;
  animation: helicopter 1.5s ease-in-out infinite;
  animation-fill-mode: both;
}
.card .back .sky {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 80px;
  width: 160px;
  overflow: hidden;
}
.card .back .sky .cloud-1 {
  position: absolute;
  right: -25px;
  top: 34px;
  height: 3px;
  width: 24.9px;
  background: #4b4841;
  border-radius: 3px;
  animation: cloud 0.8s linear 1s infinite;
}
.card .back .sky .cloud-2 {
  position: absolute;
  right: -25px;
  top: 48px;
  height: 3px;
  width: 15.3px;
  background: #4b4841;
  border-radius: 3px;
  animation: cloud 0.8s linear 0.9s infinite;
}
.card .back .sky .cloud-3 {
  position: absolute;
  right: -25px;
  top: 62px;
  height: 3px;
  width: 15.6px;
  background: #4b4841;
  border-radius: 3px;
  animation: cloud 0.7s linear 0.3s infinite;
}
.card .back .sky .cloud-4 {
  position: absolute;
  right: -25px;
  top: 76px;
  height: 3px;
  width: 21.2px;
  background: #4b4841;
  border-radius: 3px;
  animation: cloud 0.8s linear 0.2s infinite;
}
.card .back .sky .cloud-5 {
  position: absolute;
  right: -25px;
  top: 90px;
  height: 3px;
  width: 22.9px;
  background: #4b4841;
  border-radius: 3px;
  animation: cloud 0.7s linear 0.4s infinite;
}
.card .back .sky .cloud-6 {
  position: absolute;
  right: -25px;
  top: 104px;
  height: 3px;
  width: 18.5px;
  background: #4b4841;
  border-radius: 3px;
  animation: cloud 0.8s linear 0.9s infinite;
}
.card .back .sky .cloud-7 {
  position: absolute;
  right: -25px;
  top: 118px;
  height: 3px;
  width: 21.7px;
  background: #4b4841;
  border-radius: 3px;
  animation: cloud 0.8s linear 0.1s infinite;
}
.card .back .sky .cloud-8 {
  position: absolute;
  right: -25px;
  top: 132px;
  height: 3px;
  width: 25px;
  background: #4b4841;
  border-radius: 3px;
  animation: cloud 0.7s linear 0.6s infinite;
}
.card .back .sky .cloud-9 {
  position: absolute;
  right: -25px;
  top: 146px;
  height: 3px;
  width: 20.1px;
  background: #4b4841;
  border-radius: 3px;
  animation: cloud 0.7s linear 0.8s infinite;
}

@keyframes bike {
  0%, 100% {
    transform: scaleY(1);
  }
  50% {
    transform: scaleY(1.03);
  }
}
@keyframes street {
  0% {
    transform: translate3d(0, 0, 0) scaleX(1);
  }
  100% {
    transform: translate3d(-210px, 0, 0) scaleX(0.8);
  }
}
@keyframes helicopter {
  0%, 100% {
    transform: translate3d(0, -5px, 0);
  }
  50% {
    transform: translate3d(0, 5px, 0);
  }
}
@keyframes cloud {
  0% {
    transform: translateX(0) scaleX(1);
  }
  100% {
    transform: translateX(-210px) scaleX(0.8);
  }
}